<template>
  <div class="about-page">
    <section class="page-header">
      <div class="container">
        <h1 class="page-title" data-aos="fade-up">关于我</h1>
        <p class="page-description" data-aos="fade-up" data-aos-delay="100">
          了解更多关于我的专业背景、技能和经验。
        </p>
      </div>
    </section>

    <section class="section about-section">
      <div class="container">
        <div class="about-content">
          <div class="about-image" data-aos="fade-right">
            <div class="image-container">
              <img src="https://via.placeholder.com/600x600" alt="个人照片">
            </div>
          </div>
          
          <div class="about-text" data-aos="fade-left">
            <h2 class="section-title">我是谁</h2>
            <p class="about-intro">
              一位充满热情的前端开发者，拥有丰富的Web开发经验，专注于创造美观、高效且用户友好的数字体验。
            </p>
            <p class="about-description">
              我热爱将设计转化为代码，并且对细节有着极高的重视。我专注于构建响应式、高性能的Web应用程序，能够无缝地在各种设备上运行。通过持续学习和尝试新技术，我不断提升自己的技能。
            </p>
            <p class="about-description">
              除了编码之外，我还热衷于参与开源社区，分享知识和经验，并与其他开发者协作解决复杂问题。
            </p>
            
            <div class="about-stats" data-aos="fade-up">
              <div class="stat-item">
                <h3 class="stat-number">5+</h3>
                <p class="stat-text">年开发经验</p>
              </div>
              <div class="stat-item">
                <h3 class="stat-number">50+</h3>
                <p class="stat-text">完成项目</p>
              </div>
              <div class="stat-item">
                <h3 class="stat-number">20+</h3>
                <p class="stat-text">满意客户</p>
              </div>
            </div>
          </div>
        </div>
      </div>
    </section>

    <section class="section experience-section">
      <div class="container">
        <h2 class="section-title" data-aos="fade-up">工作经验</h2>
        
        <div class="timeline" data-aos="fade-up">
          <div class="timeline-item" v-for="(job, index) in experience" :key="index" data-aos="fade-up" :data-aos-delay="index * 100">
            <div class="timeline-dot"></div>
            <div class="timeline-content">
              <div class="job-date">{{ job.period }}</div>
              <h3 class="job-title">{{ job.title }}</h3>
              <div class="job-company">{{ job.company }}</div>
              <p class="job-description">{{ job.description }}</p>
            </div>
          </div>
        </div>
      </div>
    </section>

    <section class="section education-section">
      <div class="container">
        <h2 class="section-title" data-aos="fade-up">教育背景</h2>
        
        <div class="education-container" data-aos="fade-up">
          <div class="education-item" v-for="(edu, index) in education" :key="index" data-aos="fade-up" :data-aos-delay="index * 100">
            <div class="education-year">{{ edu.year }}</div>
            <div class="education-content">
              <h3 class="education-degree">{{ edu.degree }}</h3>
              <div class="education-school">{{ edu.school }}</div>
              <p class="education-description">{{ edu.description }}</p>
            </div>
          </div>
        </div>
      </div>
    </section>
  </div>
</template>

<script>
export default {
  name: 'About',
  data() {
    return {
      experience: [
        {
          title: '高级前端开发工程师',
          company: 'ABC 科技有限公司',
          period: '2020 - 至今',
          description: '负责公司主要产品的前端架构设计和开发，优化Web应用性能，指导初级开发人员，参与产品规划和技术选型。'
        },
        {
          title: '前端开发工程师',
          company: 'XYZ 网络科技',
          period: '2018 - 2020',
          description: '开发和维护多个Web应用项目，实现响应式设计，优化用户界面和体验，与后端团队协作实现全栈功能。'
        },
        {
          title: '前端开发实习生',
          company: '创新工作室',
          period: '2017 - 2018',
          description: '参与网站开发和维护，学习前端技术栈，独立完成小型项目，协助高级开发人员进行代码审查和测试。'
        }
      ],
      education: [
        {
          degree: '计算机科学学士',
          school: '某某大学',
          year: '2014 - 2018',
          description: '主修计算机科学，专注于Web开发和用户界面设计。参与了多个学生项目，并获得了优秀毕业生奖项。'
        },
        {
          degree: '网络安全认证',
          school: '在线教育平台',
          year: '2019',
          description: '完成了为期6个月的网络安全课程，学习了Web应用安全基础知识和实践技能。'
        }
      ]
    }
  }
}
</script>

<style scoped lang="scss">
.page-header {
  padding: 8rem 0 4rem;
  background: linear-gradient(to right, rgba(10, 10, 10, 0.8), rgba(10, 10, 10, 0.8)), url('https://via.placeholder.com/1920x1080') no-repeat center/cover;
  text-align: center;
  
  .page-title {
    font-size: 3rem;
    margin-bottom: 1.5rem;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
  }
  
  .page-description {
    max-width: 700px;
    margin: 0 auto;
    font-size: 1.1rem;
    color: var(--text-muted);
    line-height: 1.7;
  }
}

.about-content {
  display: flex;
  gap: 4rem;
  align-items: center;
  
  .about-image {
    flex: 1;
    
    .image-container {
      position: relative;
      max-width: 450px;
      border-radius: 8px;
      overflow: hidden;
      box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
      
      &::before {
        content: '';
        position: absolute;
        top: -20px;
        left: -20px;
        width: calc(100% + 40px);
        height: calc(100% + 40px);
        background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
        z-index: -1;
        border-radius: 8px;
        opacity: 0.5;
      }
      
      img {
        width: 100%;
        height: auto;
        display: block;
        transition: transform 0.5s ease;
        
        &:hover {
          transform: scale(1.05);
        }
      }
    }
  }
  
  .about-text {
    flex: 1.2;
    
    .about-intro {
      font-size: 1.5rem;
      font-weight: 500;
      margin-bottom: 1.5rem;
      color: var(--text-color);
      line-height: 1.5;
    }
    
    .about-description {
      color: var(--text-muted);
      margin-bottom: 1.5rem;
      line-height: 1.8;
    }
    
    .about-stats {
      display: flex;
      gap: 3rem;
      margin-top: 3rem;
      
      .stat-item {
        text-align: center;
        
        .stat-number {
          font-size: 2.5rem;
          font-weight: 700;
          margin-bottom: 0.5rem;
          background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
          -webkit-background-clip: text;
          -webkit-text-fill-color: transparent;
        }
        
        .stat-text {
          color: var(--text-muted);
          font-size: 0.9rem;
        }
      }
    }
  }
}

.experience-section {
  background: #0d0d0d;
}

.timeline {
  position: relative;
  max-width: 800px;
  margin: 3rem auto 0;
  
  &::before {
    content: '';
    position: absolute;
    top: 0;
    left: 20px;
    height: 100%;
    width: 2px;
    background: linear-gradient(to bottom, var(--primary-color), var(--secondary-color));
  }
  
  .timeline-item {
    position: relative;
    padding-left: 60px;
    margin-bottom: 3rem;
    
    &:last-child {
      margin-bottom: 0;
    }
    
    .timeline-dot {
      position: absolute;
      left: 11px;
      top: 5px;
      width: 20px;
      height: 20px;
      border-radius: 50%;
      background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
      z-index: 1;
    }
    
    .timeline-content {
      background: rgba(255, 255, 255, 0.03);
      padding: 2rem;
      border-radius: 8px;
      transition: all 0.3s ease;
      
      &:hover {
        background: rgba(255, 255, 255, 0.05);
        transform: translateY(-5px);
      }
      
      .job-date {
        font-size: 0.9rem;
        color: var(--secondary-color);
        margin-bottom: 0.5rem;
      }
      
      .job-title {
        font-size: 1.3rem;
        margin-bottom: 0.3rem;
        color: var(--text-color);
      }
      
      .job-company {
        font-size: 1rem;
        color: var(--text-muted);
        margin-bottom: 1rem;
      }
      
      .job-description {
        color: var(--text-muted);
        line-height: 1.7;
      }
    }
  }
}

.education-container {
  max-width: 800px;
  margin: 3rem auto 0;
  
  .education-item {
    display: flex;
    margin-bottom: 3rem;
    
    &:last-child {
      margin-bottom: 0;
    }
    
    .education-year {
      flex: 0 0 150px;
      font-size: 1.1rem;
      font-weight: 600;
      color: var(--secondary-color);
      position: relative;
      padding-right: 2rem;
      
      &::after {
        content: '';
        position: absolute;
        top: 12px;
        right: 0;
        width: 10px;
        height: 10px;
        border-radius: 50%;
        background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
      }
    }
    
    .education-content {
      flex: 1;
      background: rgba(255, 255, 255, 0.03);
      padding: 2rem;
      border-radius: 8px;
      transition: all 0.3s ease;
      
      &:hover {
        background: rgba(255, 255, 255, 0.05);
        transform: translateY(-5px);
      }
      
      .education-degree {
        font-size: 1.3rem;
        margin-bottom: 0.3rem;
        color: var(--text-color);
      }
      
      .education-school {
        font-size: 1rem;
        color: var(--text-muted);
        margin-bottom: 1rem;
      }
      
      .education-description {
        color: var(--text-muted);
        line-height: 1.7;
      }
    }
  }
}

@media (max-width: 992px) {
  .about-content {
    flex-direction: column;
    gap: 3rem;
    
    .about-image {
      width: 100%;
      
      .image-container {
        max-width: 350px;
        margin: 0 auto;
      }
    }
  }
  
  .education-item {
    flex-direction: column;
    
    .education-year {
      margin-bottom: 1rem;
      padding-bottom: 1rem;
      border-bottom: 1px solid rgba(255, 255, 255, 0.1);
      
      &::after {
        display: none;
      }
    }
  }
}

@media (max-width: 768px) {
  .page-header {
    padding: 6rem 0 3rem;
    
    .page-title {
      font-size: 2.2rem;
    }
  }
  
  .about-text {
    .about-intro {
      font-size: 1.2rem;
    }
    
    .about-stats {
      gap: 1.5rem;
      
      .stat-item {
        .stat-number {
          font-size: 2rem;
        }
      }
    }
  }
  
  .timeline {
    padding-left: 0;
    
    .timeline-item {
      padding-left: 40px;
    }
  }
}
</style> 